#pragma once
#include "xFrameBase.h"
#include "xnamath.h"
struct CubeVertex
{
	XMFLOAT3 Pos;
	XMFLOAT4 Color;
};

class xCube : public xFrameBase
{
public:
	xCube();
	~xCube();
private:
	xEffect			*m_pEffect;
	xTechnique		*m_pTechnique;
	ID3D11InputLayout *m_pLayout;
	ID3D11Buffer	*m_pVertexBuffer;
	ID3D11Buffer	*m_pIndexBuffer;

	D3D11_INPUT_ELEMENT_DESC* m_pLayoutDesc;
	XMMATRIX	m_World;
	XMMATRIX	m_View;
	XMMATRIX	m_Projection;
protected:
	virtual BOOL OnCreate(CREATESTRUCT *pCreate);
	virtual void OnDraw();
public:
	static xFrameBase *CreateObject();
public:
	void PrepareLayout();
	BOOL Reset(UINT nSampleCount);
	void re();
};